import {mapActions, mapGetters} from 'vuex';
//import api from 'api';

export default {
  data () {
    return {
      lang: this.$i18n.locale, // 当前语言
      menuList: [{
        "menuId": "homework_1",
        "menuNameCn":"功能",
        "menuNameEn":"功能",
        "iconCls": "el-icon-location",
        "children":[{
          "menuId": "homework_2",
          "menuNameCn":"作业布置",
        
          "iconCls": "el-icon-location",
          "children":[],
          "comp":"publish_homework",
          "url":"/publish_homework"
        }],
        "comp":"",
        "url":""
      },{
        "menuId": "homework_3",
        "menuNameCn":"作业历史记录",
       
        "iconCls": "el-icon-location",
        "children":[],
        "comp":"history",
        "url":"/history"
      }
      ], // 菜单集合
      showMenuFlag: true, // 是否展示菜单
      isCollapse: false // 是否折叠菜单

    };
  },

  methods: {
    ...mapActions([ // https://vuex.vuejs.org/zh-cn/actions.html
      'homeworkAddTab',
      'homeworkRemoveTab',
      'homeworkClickTab'
    ])
  },
  computed: {
    ...mapGetters([ // https://vuex.vuejs.org/zh-cn/getters.html
      'getHomeworkHomeCurrentTab',
      'getHomeworkHomeTabs'
    ])
  },
  components: {
    
    publish_homework: () => import('views/HomeworkManage/publish_homework/publish_homework.vue'),
    history: () => import('views/comp/homeworkhistory.vue'),
  }
};
